import React, {Component} from 'react'
import {InputText} from "primereact/inputtext";
import {Dropdown} from "primereact/dropdown";
import {InputTextarea} from "primereact/inputtextarea";

export default class TransferD extends Component {


    constructor() {
        super()

        this.state = {
            transferItems: null,
        }

        this.onTransferItemsChange = this.onTransferItemsChange.bind(this)
    }


    onTransferItemsChange(e) {
        this.setState({transferItems: e.value});
    }

    render() {
        const transferSelectItems = [
            {name: 'EOS', code: 'NY'},
            {name: 'EOS2', code: 'RM'},
            {name: 'EOS3', code: 'LDN'}
        ]

        return (
            <div className="card" style={{minHeight: "400px"}}>
                <div className="p-fluid">
                    <div className="p-g-12">
                        <label>转账币名</label>
                        <Dropdown

                            value={this.state.transferItems}
                            options={transferSelectItems}
                            onChange={this.onTransferItemsChange}
                            style={{width: '100%'}}
                            placeholder="EOS"
                            optionLabel="name"
                        />
                    </div>


                    <div className="p-g-12">
                        <label>账户名称</label>
                        <InputText placeholder="转出账户"/>
                    </div>


                    <div className="p-g-12">
                        <label>转账数量</label>
                        <InputText placeholder="请输入转出金额"/>
                    </div>


                    <div className="p-g-12">
                        <InputTextarea placeholder="备注"/>
                    </div>
                </div>
            </div>
        )
    }
}